﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace XNA_Game_Framework
{
	public partial class InputHandler
	{
		public delegate void KeyPressedEventHandler(object sender, KeyPressedEventArgs e);
		public delegate void MouseEventHandler(object sender, MouseEventArgs e);

		#region KeyPressed
		public event KeyPressedEventHandler KeyboardPressed;
		public event KeyPressedEventHandler AKeyPressed;
		public event KeyPressedEventHandler BKeyPressed;
		public event KeyPressedEventHandler CKeyPressed;
		public event KeyPressedEventHandler DKeyPressed;
		public event KeyPressedEventHandler EKeyPressed;
		public event KeyPressedEventHandler FKeyPressed;
		public event KeyPressedEventHandler GKeyPressed;
		public event KeyPressedEventHandler HKeyPressed;
		public event KeyPressedEventHandler IKeyPressed;
		public event KeyPressedEventHandler JKeyPressed;
		public event KeyPressedEventHandler KKeyPressed;
		public event KeyPressedEventHandler LKeyPressed;
		public event KeyPressedEventHandler MKeyPressed;
		public event KeyPressedEventHandler NKeyPressed;
		public event KeyPressedEventHandler OKeyPressed;
		public event KeyPressedEventHandler PKeyPressed;
		public event KeyPressedEventHandler QKeyPressed;
		public event KeyPressedEventHandler RKeyPressed;
		public event KeyPressedEventHandler SKeyPressed;
		public event KeyPressedEventHandler TKeyPressed;
		public event KeyPressedEventHandler UKeyPressed;
		public event KeyPressedEventHandler VKeyPressed;
		public event KeyPressedEventHandler WKeyPressed;
		public event KeyPressedEventHandler XKeyPressed;
		public event KeyPressedEventHandler YKeyPressed;
		public event KeyPressedEventHandler ZKeyPressed;
		public event KeyPressedEventHandler BackSpaceKeyPressed;
		public event KeyPressedEventHandler DownKeyPressed;
		public event KeyPressedEventHandler EnterKeyPressed;
		public event KeyPressedEventHandler EscKeyPressed;
		public event KeyPressedEventHandler UpKeyPressed;

		protected virtual void OnKeyPressed(KeyPressedEventArgs e)
		{
			if (KeyboardPressed != null)
			{
				KeyboardPressed(this, e);
			}
		}

		protected virtual void OnAKeyPressed(KeyPressedEventArgs e)
		{
			if (AKeyPressed != null)
			{
				AKeyPressed(this, e);
			}
		}

		protected virtual void OnBKeyPressed(KeyPressedEventArgs e)
		{
			if (BKeyPressed != null)
			{
				BKeyPressed(this, e);
			}
		}

		protected virtual void OnCKeyPressed(KeyPressedEventArgs e)
		{
			if (CKeyPressed != null)
			{
				CKeyPressed(this, e);
			}
		}

		protected virtual void OnDKeyPressed(KeyPressedEventArgs e)
		{
			if (DKeyPressed != null)
			{
				DKeyPressed(this, e);
			}
		}

		protected virtual void OnEKeyPressed(KeyPressedEventArgs e)
		{
			if (EKeyPressed != null)
			{
				EKeyPressed(this, e);
			}
		}

		protected virtual void OnFKeyPressed(KeyPressedEventArgs e)
		{
			if (FKeyPressed != null)
			{
				FKeyPressed(this, e);
			}
		}

		protected virtual void OnGKeyPressed(KeyPressedEventArgs e)
		{
			if (GKeyPressed != null)
			{
				GKeyPressed(this, e);
			}
		}

		protected virtual void OnHKeyPressed(KeyPressedEventArgs e)
		{
			if (HKeyPressed != null)
			{
				HKeyPressed(this, e);
			}
		}

		protected virtual void OnIKeyPressed(KeyPressedEventArgs e)
		{
			if (IKeyPressed != null)
			{
				IKeyPressed(this, e);
			}
		}

		protected virtual void OnJKeyPressed(KeyPressedEventArgs e)
		{
			if (JKeyPressed != null)
			{
				JKeyPressed(this, e);
			}
		}

		protected virtual void OnKKeyPressed(KeyPressedEventArgs e)
		{
			if (KKeyPressed != null)
			{
				KKeyPressed(this, e);
			}
		}

		protected virtual void OnLKeyPressed(KeyPressedEventArgs e)
		{
			if (LKeyPressed != null)
			{
				LKeyPressed(this, e);
			}
		}

		protected virtual void OnMKeyPressed(KeyPressedEventArgs e)
		{
			if (MKeyPressed != null)
			{
				MKeyPressed(this, e);
			}
		}

		protected virtual void OnNKeyPressed(KeyPressedEventArgs e)
		{
			if (NKeyPressed != null)
			{
				NKeyPressed(this, e);
			}
		}

		protected virtual void OnOKeyPressed(KeyPressedEventArgs e)
		{
			if (OKeyPressed != null)
			{
				OKeyPressed(this, e);
			}
		}

		protected virtual void OnPKeyPressed(KeyPressedEventArgs e)
		{
			if (PKeyPressed != null)
			{
				PKeyPressed(this, e);
			}
		}

		protected virtual void OnQKeyPressed(KeyPressedEventArgs e)
		{
			if (QKeyPressed != null)
			{
				QKeyPressed(this, e);
			}
		}

		protected virtual void OnRKeyPressed(KeyPressedEventArgs e)
		{
			if (RKeyPressed != null)
			{
				RKeyPressed(this, e);
			}
		}

		protected virtual void OnSKeyPressed(KeyPressedEventArgs e)
		{
			if (SKeyPressed != null)
			{
				SKeyPressed(this, e);
			}
		}

		protected virtual void OnTKeyPressed(KeyPressedEventArgs e)
		{
			if (TKeyPressed != null)
			{
				TKeyPressed(this, e);
			}
		}

		protected virtual void OnUKeyPressed(KeyPressedEventArgs e)
		{
			if (UKeyPressed != null)
			{
				UKeyPressed(this, e);
			}
		}

		protected virtual void OnVKeyPressed(KeyPressedEventArgs e)
		{
			if (VKeyPressed != null)
			{
				VKeyPressed(this, e);
			}
		}

		protected virtual void OnWKeyPressed(KeyPressedEventArgs e)
		{
			if (WKeyPressed != null)
			{
				WKeyPressed(this, e);
			}
		}

		protected virtual void OnXKeyPressed(KeyPressedEventArgs e)
		{
			if (XKeyPressed != null)
			{
				XKeyPressed(this, e);
			}
		}

		protected virtual void OnYKeyPressed(KeyPressedEventArgs e)
		{
			if (YKeyPressed != null)
			{
				YKeyPressed(this, e);
			}
		}

		protected virtual void OnZKeyPressed(KeyPressedEventArgs e)
		{
			if (ZKeyPressed != null)
			{
				ZKeyPressed(this, e);
			}
		}

		protected virtual void OnBackSpaceKeyPressed(KeyPressedEventArgs e)
		{
			if (BackSpaceKeyPressed != null)
			{
				BackSpaceKeyPressed(this, e);
			}
		}

		protected virtual void OnDownKeyPressed(KeyPressedEventArgs e)
		{
			if (DownKeyPressed != null)
			{
				DownKeyPressed(this, e);
			}
		}

		protected virtual void OnEnterKeyPressed(KeyPressedEventArgs e)
		{
			if (EnterKeyPressed != null)
			{
				EnterKeyPressed(this, e);
			}
		}

		protected virtual void OnEscKeyPressed(KeyPressedEventArgs e)
		{
			if (EscKeyPressed != null)
			{
				EscKeyPressed(this, e);
			}
		}

		protected virtual void OnUpKeyPressed(KeyPressedEventArgs e)
		{
			if (UpKeyPressed != null)
			{
				UpKeyPressed(this, e);
			}
		}
		#endregion

		#region Mouse
		public event MouseEventHandler LeftButtonPressed;
		public event MouseEventHandler RightButtonPressed;
		public event MouseEventHandler MouseMoved;
		public event MouseEventHandler MouseLeftDrag;
		public event MouseEventHandler MouseRightDrag;

		protected virtual void OnLeftButtonPressed(MouseEventArgs e)
		{
			if (LeftButtonPressed != null)
			{
				LeftButtonPressed(this, e);
			}
		}

		protected virtual void OnRightButtonPressed(MouseEventArgs e)
		{
			if (RightButtonPressed != null)
			{
				RightButtonPressed(this, e);
			}
		}

		protected virtual void OnMouseMoved(MouseEventArgs e)
		{
			if (MouseMoved != null)
			{
				MouseMoved(this, e);
			}
		}

		protected virtual void OnMouseLeftDrag(MouseEventArgs e)
		{
			if (MouseLeftDrag != null)
			{
				MouseLeftDrag(this, e);
			}
		}

		protected virtual void OnMouseRightDrag(MouseEventArgs e)
		{
			if (MouseRightDrag != null)
			{
				MouseRightDrag(this, e);
			}
		}
		#endregion
	}
}
